from plat.plat_train import get_train_info, plat_train_val, plat_trains

"""
比较是否使用dropout和weight_decay的效果
nothing: dropout和weight_decay均未使用
drop: 只使用了dropout
decay: 只使用了weight_decay
drop_decay: dropout和weight_decay都使用了
"""
if __name__ == '__main__':
    log_path = "../log/GatedGCN/drop/"
    nothing = "nothing.log"
    drop = "drop.log"
    decay = "decay.log"
    drop_decay = "drop_decay.log"
    train_dict = dict()
    val_dict = dict()
    train_dict['nothing'], val_dict['nothing'] = get_train_info(log_path + nothing)
    train_dict['drop'], val_dict['drop'] = get_train_info(log_path + drop)
    train_dict['decay'], val_dict['decay'] = get_train_info(log_path + decay)
    train_dict['drop_decay'], val_dict['drop_decay'] = get_train_info(log_path + drop_decay)
    plat_train_val('nothing', train_dict['nothing'], val_dict['nothing'])
    plat_train_val('drop', train_dict['drop'], val_dict['drop'])
    plat_train_val('decay', train_dict['decay'], val_dict['decay'])
    plat_train_val('drop_decay', train_dict['drop_decay'], val_dict['drop_decay'])
    plat_trains(train_dict)
    plat_trains(val_dict)
